package com.qf.mocks;

import com.qf.pojo.Order;
import com.qf.service.OrderService;
import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;

//@Component
public class OrderServiceMock implements OrderService {
    @Override
    public List<Order> findByUid(Integer uid) throws InterruptedException {
        //一旦远程访问失败后，会执行这个降级方法，我们在这里返回一些伪装数据，而不是让用户看到错误页面
        return new ArrayList<>();
    }
}
